package com.weipai.springboot.module.service;

import com.weipai.springboot.model.api.Response;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;

public interface PayService {
    Response getPayModeList();

    //支付宝支付
    Response aliPay(String orderNumber, int payment, String source);

    //微信支付
    Response wxPay(String orderNumber, int payment, String spbillCreateIp, String source);

    Response wxPayJsapi(HttpServletRequest request,String orderNumber,Integer payment,String spbillCreateIp, String source,String customerId);



    //到付
    Response collectPay(String orderNumber, int payment, String source);

    //银联付款
    void unionPay(HttpServletResponse resp, String orderNumber, String txnAmt, String txnTime);

    //微信回调
    String wxPayNotify(HttpServletRequest request);

    //支付宝回调
    String aliPayNotify(HttpServletRequest request);

    //银联支付回调
    void unionPayNotify(HttpServletRequest req, HttpServletResponse resp);

    //信誉值支付
    Response reputationPay(String orderNumber, int i, String source);

    //积分换购商品
    Response integralRedemption(String integralAmount, String goodsId);

    //支付宝提现
    Response getWithdrawals(Integer money);

    //  信誉值支付 密码验证
    Response verPasswords(String customerId, String password);

    //微信pc端扫码支付
    Response wxEwmPay(String orderNumber, Integer payment, String spbillCreateIp, String source, HttpServletResponse httpRespon);

    //微信pc扫码支付回调接口
    void wxEwmPayNotify(HttpServletRequest request, HttpServletResponse response);

    //支付宝pc端扫码支付
    void aliEwmPay(String orderNumber, Integer payment, String source, HttpServletResponse httpRespon);

    //微信pc支付监听此订单是否支付成功
    Response timerWxEwmPay(String orderNumber);

    void goFrontUrl(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException;

}
